package com.newly.center.sys.api;

import com.newly.api.sys.feign.TestClient;
import com.newly.center.sys.service.test.api.ITestService;
import com.newly.common.base.constants.ServerUriConstant;
import com.newly.common.base.entity.R;
import com.newly.common.base.entity.auth.ICurrentTenant;
import com.newly.common.base.entity.test.TestBean1;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @program: newly-parent
 * @remark: 测试
 * @author: guan
 * @create: 2022-01-08 17:08
 */
@RestController
@RequestMapping(ServerUriConstant.NEWLY_SYS_TEST)
public class TestApi implements TestClient {

    @Autowired
    private ITestService testService;

    @Override
    public R test01() {
        ICurrentTenant currentTenant = null;
        testService.test01(currentTenant, "aaaa");
        return R.ok("success");
    }

    @Override
    public R test02(TestBean1 testBean1) {
        testService.test02(testBean1);
        return R.ok("success");
    }
}
